//
//  FTDrawerController.m
//  Holyiot-DFU
//
//  Created by bill on 2023/2/13.
//

#import "FTDrawerController.h"
#import "FTNavgationController.h"
#import "SystemInfoVC.h"
#import "DeviceListVC.h"
#import <MMDrawerVisualState.h>
@interface FTDrawerController ()

@end

@implementation FTDrawerController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.view.backgroundColor = [UIColor blackColor];
    
    FTNavgationController * left = [[FTNavgationController alloc] initWithRootViewController:[SystemInfoVC new]];
    self.leftDrawerViewController = left;
    self.centerViewController = [[FTNavgationController alloc]initWithRootViewController:[[DeviceListVC alloc]init]];
    
    //设置阴影
    [self setShowsShadow:YES];
    [self setRestorationIdentifier:@"MMDrawer"];
    //设置可见宽度
    [self setMaximumLeftDrawerWidth:[UIScreen mainScreen].bounds.size.width * VisibleMargin];
    //弹簧效果
    self.shouldStretchDrawer = YES;
    //设置打开侧边栏的手势
    [self setOpenDrawerGestureModeMask:MMOpenDrawerGestureModeNone];
    //设置关闭侧边栏的手势
    [self setCloseDrawerGestureModeMask:MMCloseDrawerGestureModeAll];
    
    
    
    //设置动画
    [self setDrawerVisualStateBlock:[MMDrawerVisualState slideAndScaleVisualStateBlock]];
}



@end
